<template>
	<view class="flex-col page">
		<view class="flex-col group" v-if="article.length>0">
			<text class="text_1">
				<u-parse :content="article"></u-parse>
			</text>
		</view>
		<view v-else>
			<u-empty mode="data" width="250" textSize="25" marginTop="50%" icon="http://cdn.uviewui.com/uview/empty/data.png">
			</u-empty>
		</view>
	</view>
</template>

<script>
	export default {
		components: {},
		data() {
			return {
				article: '',
				identification:'',
				articleTitle: ''
			};
		},
		onLoad(option) {
			console.log('121332' + option)

			if (option.hasOwnProperty('id')) {
				this.id = option.id
				this.getIdentification(this.id);
			} else {
				// this.$u.toast('参数异常');
			}

		},
		
		methods: {
			getIdentification(id) {
				this.$http('message.viewNotice', {
					noticeId: id
				}).then(r => {
					// console.log(r);
					if (r.code == 200) {
						this.article = r.data.details;
						this.articleTitle = r.data.title;
						uni.setNavigationBarTitle({
							title: this.title
						});

					}
				})
			}
		},
	};
</script>

<style scoped lang="scss">
	.page {
		background-color: #ffffffff;
		width: 100%;
		overflow-y: auto;
		overflow-x: hidden;
		height: 100%;
	}

	.group {
		padding: 32rpx 32rpx 368rpx;
		flex: 1 1 auto;
		overflow-y: auto;
	}

	.text_1 {
		color: #191919;
		font-size: 32rpx;
		font-family: '.AppleSystemUIFont';
		line-height: 38rpx;
		text-align: left;
	}

	.text_2 {
		margin-top: 46rpx;
		color: #333333;
		font-size: 28rpx;
		font-family: '.AppleSystemUIFont';
		line-height: 33rpx;
		text-align: left;
		text-indent: 37rpx;
	}
</style>
